import request from '@/utils/request'

export function list (parameter) {
  return request({
    url: '/boss/project/visit/config/list',
    method: 'post',
    data: parameter
  })
}
export function add (parameter) {
  return request({
    url: '/boss/project/visit/config/add',
    method: 'post',
    data: parameter
  })
}
export function updataEdit (parameter) {
  return request({
    url: '/boss/project/visit/config/updateDetail',
    method: 'post',
    data: parameter
  })
}
export function updata (parameter) {
  return request({
    url: '/boss/project/visit/config/update',
    method: 'post',
    data: parameter
  })
}
export function getVisitStagesByVersion (parameter) {
  return request({
    url: '/boss/project/visit/config/listDetail',
    method: 'post',
    data: parameter
  })
}
export function visitStageByFeeCategory (parameter) {
  return request({
    url: '/v2/boss/project/cost/visitStageByFeeCategory',
    method: 'post',
    data: parameter
  })
}
export function getVisitExport (parameter) {
  return request({
    url: '/boss/project/visit/config/export',
    method: 'get',
    params: parameter,
    responseType: 'blob'
  })
}
export function visitImport (parameter) {
  return request({
    url: '/boss/project/visit/config/import',
    method: 'post',
    data: parameter,
    headers: {
      'Content-Type': 'multipart/form-data'
    }
  })
}
